package com.students.mapper;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.students.pojo.Employee;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import io.lettuce.core.dynamic.annotation.Param;

import java.time.LocalDate;
import java.util.List;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author caohanqing
 * @since 2022-04-06
 */
public interface EmployeeMapper extends BaseMapper<Employee> {

    //获取所有员工(分页)
    IPage<Employee> getEmployeeByPage(
            Page<Employee> page,
            @Param("employee")Employee employee,
            @Param("beginDateScope") LocalDate[] beginDateScope);

    //查询员工
    List<Employee> getEmployee(Integer id);

    //获取所有员工套账
    IPage<Employee> getEmployeeWithSalary(Page<Employee> page);
}
